package org.glut.saltedfish.domain;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;

import java.util.Date;

@Data
@AllArgsConstructor
@NoArgsConstructor
@ToString
public class Order {
    private Integer id;
    private String orderNo;
    private Integer buyerId;
    private Integer sellerId;
    private Integer productId;
    private Double amount;
    private Integer status;
    private String address;
    private String contactPhone;
    private String remark;
    private Date createdAt;
    private Date updatedAt;

    private User seller;//卖家
    private User buyer;//买家
    private Product product;//商品
    // 分页相关字段（不持久化到数据库）
    private transient Integer offset;
    private transient Integer pageSize;
    //商品标题搜索
    private transient String productTitle;

}
